# -*- mode: snippet -*-
# name: idiom, trim whitespace from std::string
# key: trim
# --
std::string::iterator ${1:itr} = std::remove(${2:str}.begin(), $2.end(), ' ');
$2.erase($1, $2.end());

